{% set clazz = "status" %}
{% set title = "状态追踪" %}
{% extends './modules/common/templates/main.html' %}
{% block style %}
  <link rel="stylesheet" type="text/css" href="{{ '/static/css/delivery.css'|version }}" />
{% endblock %}
{% block content %}
  {% if !nested %}
    <header class="bar bar-header">
      {{ macro.back() }}
      <h1 class="title">{{ title }}</h1>
    </header>
  {% endif %}
  <section>
    <div class="list compact overlap">
      <div class="item-divider">
        <div class="statu">
          <div class="sline"></div>
          {% for item in entity.statusData4AppList %}
          <div class="scontent">
            <div class="sdate">
              <p class="year">{{item.time | date('Y-m-d')}}</p>
              <p class="time">{{item.time | date('H:i')}}</p>
            </div>
            <div class="circle text-orange"></div>
            <div class="smsg">
              <h3 class="state text-orange">{{item.status | deliveryStatusFilter}}</h3>
              {% if item.status == 0 %}
              <p class="text cont"></p>
              {% elif item.status == 1 %}
              <p class="text cont">您已抢单成功，请尽快到 {{entity.projectName}} 物业处领取配送单中所含快递。</p>
              {% elif item.status == 2 %}
              <p class="text cont">您已领取快递，请电话联系用户，确定具体配送时间，尽快将快递送给用户。</p>
              {% elif item.status == 3 %}
              <p class="text cont">用户已签收，您已完成本次配送！</p>
              {% elif item.status == 4 %}
              <p class="text cont">用户已完成本次评价。</p>
              {% elif item.status == 5 %}
              <p class="text cont">用户已取消本次配送服务，请将快递归还至物业。</p>
              {% elif item.status == 8 %}
              <p class="text cont">管家已取消本次配送服务，请将快递归还至物业。</p>
              {% elif item.status == 6 %}
              <p class="text cont">您已将快递归还至物业，本次配送服务已取消，您可以继续抢单了。</p>
              {% elif item.status == 9 %}
              <p class="text cont">您已将快递归还至物业，本次配送服务已取消，您可以继续抢单了。</p>
              {% elif item.status == 7 %}
              <p class="text cont">非常抱歉，在超过指定日期24小时后，<br/>您的配送单仍无人接单，本配送单已被取消。</p>
              {% endif %}
            </div>
          </div>
          {% endfor %}
        </div>
      </div>
    </div>
  </section>
{% endblock %}
{% block script %}
  {% parent %}
  <script src="{{ '/static/js/delivery.js'|version }}"></script>
{% endblock %}